package com.yc.vote.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import java.time.LocalDate;
import java.util.List;

/**
 * <p>
 * 
 * </p>
 *
 * @author lyl
 * @since 2022-11-06
 */
public class Vote implements Serializable {

    private static final long serialVersionUID = 1L;

    // 统计参与人数的 计算列
    private int users;

    public int getUsers() {
        return users;
    }

    public void setUsers(int users) {
        this.users = users;
    }

    // 选项集合
    private List<Items> items;

    public List<Items> getItems() {
        return items;
    }

    public void setItems(List<Items> items) {
        this.items = items;
    }

    @TableId(value = "id", type = IdType.AUTO)
      private Integer id;

    private String vname;

    private String vtype;

    private LocalDate startDate;

    private LocalDate endDate;

    
    public Integer getId() {
        return id;
    }

      public void setId(Integer id) {
          this.id = id;
      }
    
    public String getVname() {
        return vname;
    }

      public void setVname(String vname) {
          this.vname = vname;
      }
    
    public String getVtype() {
        return vtype;
    }

      public void setVtype(String vtype) {
          this.vtype = vtype;
      }
    
    public LocalDate getStartDate() {
        return startDate;
    }

      public void setStartDate(LocalDate startDate) {
          this.startDate = startDate;
      }
    
    public LocalDate getEndDate() {
        return endDate;
    }

      public void setEndDate(LocalDate endDate) {
          this.endDate = endDate;
      }

    @Override
    public String toString() {
        return "Vote{" +
              "id=" + id +
                  ", vname=" + vname +
                  ", vtype=" + vtype +
                  ", startDate=" + startDate +
                  ", endDate=" + endDate +
              "}";
    }
}
